<?php
  $dbname = "anbao";
  $host = "cdb-nvevrajx.gz.tencentcdb.com:10025";
  $user = "root";
  $pwd = "lkn330881";
  $link = mysql_connect($host,$user,$pwd);
  mysql_query("set names 'utf8'",$link);
  if (!$link) die("Connect Server Failed: " . mysql_error($link));
  if (!mysql_select_db($dbname,$link)) die("Select Database Failed: " . mysql_error($link));
  include("preload.php");
  include("issue.php");

  
  $command = $_POST['url'];
  switch ($command) {
    case 'test': print_r('success'); break; 

    case 'login': login(); break;
   
    case 'register': register(); break;
    case 'updateUser': updateUser(); break;

    case 'getIssue': getIssue(); break;
    case 'submit': submit(); break;

    
    default: print_r(json_encode('Url Error'));  
  }

  
  
?>



